unit uFrmActionHeranca;

interface

uses
  Controls, Classes, Forms, ImgList, DB, DBActns,
  ActnList, PlatformDefaultStyleActnCtrls, ActnMan;

type
  TFrmActionHeranca = class(TForm)
    ActHeranca: TActionManager;
    DataSetInsert1: TDataSetInsert;
    DataSetDelete1: TDataSetDelete;
    DataSetEdit1: TDataSetEdit;
    DataSetPost1: TDataSetPost;
    DataSetCancel1: TDataSetCancel;
    ImageList1: TImageList;
    actCadBancos: TAction;
    constructor create(Awoner: TComponent; DataSource: TDataSource); reintroduce;
  end;

  { var
    FrmActionHeranca: TFrmActionHeranca; }

implementation

{$R *.dfm}
{ TForm2 }

constructor TFrmActionHeranca.create(Awoner: TComponent;
  DataSource: TDataSource);
var
  i: integer;
  Act: TComponent;
begin
  inherited create(Awoner);
  for i := 0 to pred(ActHeranca.ActionCount) do
    if ActHeranca.Actions[i].ClassNameIs('TDataSetAction') then
      for Act in ActHeranca.Actions[i].ActionList do
        TDataSetAction(Act).DataSource := DataSource;
end;

end.
